import li8n from "~/li8n.json";
import env from "./env";

type TLanguage = "en" | "cn" | "vn" | "my";

const conf: {
  [k: string]: {
    baseURL: string;
    language: TLanguage;
    href: string;
  }
} = {
  en: {
    baseURL: "https://api-en.gzfabric.com",
    language: "en",
    href: "https://www.gzfabric.com",
  },
  cn: {
    baseURL: "https://api-cn.gzfabric.com",
    language: "cn",
    href: "https://www.gzfabric.cn",
  },
  vn: {
    baseURL: "https://api-vn.gzfabric.com",
    language: "vn",
    href: "https://www.antinoriborgia.vn",
  },
  my: {
    baseURL: "https://api-my.gzfabric.com",
    language: "my",
    href: "https://www.antinoriborgia.my",
  },
}

const language = li8n[conf[env].language];

export default conf[env];
export { language, conf };
